/*
 * WorxAction.java
 * 
 * Created on Mar 13, 2006
 * David Connell
 * Copyright (c) 2006 Synergy Systems, Inc
 */
package org.puresilk.afx.web;

// java support
import javax.servlet.http.*;

// silk support
import org.puresilk.base.WebAction;

/**
 * Common ancestor for DWMS Actions to
 * provide standard application level plumbing.
 * 
 * @author David Connell
 */
public abstract class SilkAfxAction extends WebAction {
	
	/** default returns the site index page */
	public String execute(HttpServletRequest req) {
		return "/index.jsp";
	}
	
	/**
	 * Common check for session detection
	 * 
	 * @param req
	 * @return
	 */
	protected boolean sessionCheck(HttpServletRequest req) {
		boolean rv = true;
		
		HttpSession sess = req.getSession(false);
		if(sess == null)
			rv = false;
		
		return rv;
	}

}
